package com.sandasai.action.admin;

import javax.annotation.Resource;

import org.springframework.context.annotation.Scope;
import org.springframework.stereotype.Controller;

import com.opensymphony.xwork2.ActionSupport;
import com.sandasai.service.AdminManager;
import com.sandasai.vo.StudentBean;
@Controller
@Scope("prototype")
public class ShowStuInfoAction extends ActionSupport {
	/**
	 * 
	 */
	private static final long serialVersionUID = 1L;
	@Resource
	private AdminManager adminManager;
	private int id;
	private StudentBean stu;
	
	public StudentBean getStu() {
		return stu;
	}
	public void setStu(StudentBean stu) {
		this.stu = stu;
	}
	public String execute() throws Exception{
		stu = this.adminManager.findByStuId(id);
		//System.out.println(stu.getRealName());
		return SUCCESS;
	}
	public int getId() {
		return id;
	}
	public void setId(int id) {
		this.id = id;
	}
}
